package com.mall.mymall.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.mall.mymall.dao.dto.ProductDto;
import com.mall.mymall.dao.dto.StoresDto;
import com.mall.mymall.dao.dto.query.ProductsQuery;
import com.mall.mymall.dao.dto.query.StoreQuery;
import com.mall.mymall.dao.entity.Products;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author 十里坡
 * @since 2025-03-06
 */
public interface ProductsMapper extends BaseMapper<Products> {

    IPage<ProductDto> selectProductsPage(Page<ProductDto> page, @Param("query") ProductsQuery query);

    int updateProductImage(@Param("productId") Long productId, @Param("image") String image);


    List<Products> search(@Param("keyword") String keyword);
}
